//---------------------------------------------------------------------------

#ifndef CUrlLblH
#define CUrlLblH
//---------------------------------------------------------------------------
#include <SysUtils.hpp>
#include <Controls.hpp>
#include <Classes.hpp>
#include <Forms.hpp>
#include <StdCtrls.hpp>
#include "CtrlStd.h"
//---------------------------------------------------------------------------
class PACKAGE_CTRLSTD CUrlLabel : public TCustomLabel
{
private:
  bool       m_bMouseEnter;
  TColor     m_eSaveColor;
  TColor     m_eHighlightColor;
  AnsiString m_strUrl;

	void __fastcall CMMouseEnter( TMessage &Message);
	void __fastcall CMMouseLeave( TMessage &Message);

  void __fastcall SetHighLightColor( TColor eColor);
  void __fastcall SetUrl( const AnsiString strUrl);

protected:
	BEGIN_MESSAGE_MAP
		MESSAGE_HANDLER( CM_MOUSEENTER, TMessage, CMMouseEnter)
		MESSAGE_HANDLER( CM_MOUSELEAVE, TMessage, CMMouseLeave)
	END_MESSAGE_MAP( TCustomLabel);

  DYNAMIC void __fastcall MouseDown( TMouseButton Button, TShiftState Shift, int X, int Y);



public:
  __fastcall CUrlLabel(TComponent* Owner);

__published:
  __property Align;
	__property Alignment;
	__property Anchors;
	__property AutoSize;
  __property Caption;
	__property Color;
	__property Constraints;
  __property Cursor                    = { default=crHandPoint	                                           };
  __property Font;
  __property TColor     HighlightColor = { read=m_eHighlightColor, write=SetHighLightColor, default=clBlue };
	__property Layout;
	__property ParentColor;
	__property ParentFont;
	__property ParentShowHint;
	__property ShowHint;
	__property Transparent;
  __property AnsiString Url            = { read=m_strUrl         , write=SetUrl                            };
	__property Visible;

};
//---------------------------------------------------------------------------
#endif
